import random

def generate_hand(group_size, group_count):
    """
    生成 group_count 个 group_size 大小的连续组牌。
    """
    hand = []
    start = 1
    for _ in range(group_count):
        group = list(range(start, start + group_size))
        hand.extend(group)
        start += random.randint(1, 3)  # 保证组之间可能有间隔
    random.shuffle(hand)
    return hand

if __name__ == "__main__":
    group_size = 3
    group_count = 5
    hand = generate_hand(group_size, group_count)
    print("hand =", hand)
    print("groupSize =", group_size)
